package study.rpc.dubbo.api.protocol;

import lombok.Data;
import study.rpc.dubbo.api.Request;
import study.rpc.dubbo.api.Response;

import javax.ws.rs.Consumes;
import javax.ws.rs.GET;
import javax.ws.rs.Path;
import javax.ws.rs.Produces;
import javax.ws.rs.core.MediaType;

@Path("/rest")
@Consumes({MediaType.APPLICATION_JSON, MediaType.TEXT_PLAIN})
@Produces({MediaType.APPLICATION_JSON, MediaType.TEXT_PLAIN})
public interface RestService {

    @GET
    @Path("/echo")
    Response echo(Request request);
}
